﻿<!DOCTYPE html>
<html>
<head>
    <title>表单处理</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <link href="/ViewV5/CSS/bootstrap3.3.5/css/bootstrap.min.css" rel="stylesheet" />
    <link rel="stylesheet" type="text/css" href="/ViewV5/CSS/animate.css">
    <link rel="stylesheet" type="text/css" href="/ViewV5/CSS/index.css?v=1">
    <link rel="stylesheet" type="text/css" href="/ViewV5/CSS/default.css">
    <link href="/ViewV5/JS/element/index.css" rel="stylesheet" />
    <link rel="stylesheet" type="text/css" href="/ViewV5/CSS/FORMBI.css?v=3">
    <link rel="stylesheet" href="http://at.alicdn.com/t/font_533449_zsibbu1n60f.css">

    <style>
        .iconfont {
            margin-right: 4PX;
            font-size: 18px;
        }

        .widthmax {
            width: 100%;
        }

        .pd40 {
            padding: 40px;
        }

        .pd0 {
            padding: 0;
        }

        .disdiv {
            margin-left: 10PX;
        }

        .el-message-box {
            width: 320px !important;
        }

        .el-form-item__content img {
            max-width: 100% !important;
        }
    </style>

</head>
<body class="BG">
    <div id="Loading">
        <div class="loader-inner ball-beat">
            <div></div>
            <div></div>
            <div></div>
        </div>
    </div>
    <div id="DATABI_YBZZ" class="FormV" style="display:none">
        <el-container>
            <el-main class="elmain pd40">

                <div class="panel-df " id="princontent">
                    <div class="container containerb" v-bind:class="{ width840: poption.width=='0'}" style="padding:0;    box-shadow: 0 8px 18px 0 rgba(0,0,0,.1);">
                        <div class="panel panel-defaul  panhead" style="border: 1px solid #ebeef5;padding-bottom: 10px;">
                            <div class="success-tip" v-show="pidata.isGD=='Y'&&vtype == '0'" style="width: 100px;right: 25%;left: auto;">
                                已归档
                            </div>
                            <div class="success-tip" v-show="pidata.isComplete=='Y'&&vtype == '0'" style="width: 120px;left: 30%;right: auto;">
                                流程已结束
                            </div>

                            <el-row>

                                <el-col :xs="24" :sm="24">
                                    <h4 class="text-center">
                                        <span v-text="pddata.ProcessName" style="font-size: 24PX;font-family: cursive;font-weight: 700;"></span>
                                        <el-tooltip class="item" effect="dark" content="表单填写说明" placement="top-start">
                                            <i class="el-icon-question hidden-print" v-show="pddata.Alias" style="color: cornflowerblue;" @click="FormDecVisible = true"></i>
                                        </el-tooltip>
                                        <el-dropdown style="float:right;" @command="handleCommand" class="hidden-print">
                                            <i class="el-icon-more el-dropdown-link"></i>
                                            <el-dropdown-menu slot="dropdown">
                                                <el-dropdown-item command="CopyForm">重新发起</el-dropdown-item>
                                                <el-dropdown-item command="UpdateTemp">更新模板</el-dropdown-item>
                                                <el-dropdown-item v-if="vtype!='1'" command="Export">导出Word</el-dropdown-item>
                                                <el-dropdown-item v-if="vtype!='1'" command="Preview">打印</el-dropdown-item>
                                                <el-dropdown-item v-if="vtype!='1'" command="qp">全屏</el-dropdown-item>
                                                <el-dropdown-item v-if="vtype!='1'" command="zdh">最大化</el-dropdown-item>


                                            </el-dropdown-menu>
                                        </el-dropdown>
                                    </h4>
                                    <p style="text-align:center; margin-top: 10px;color: gray;font-family: cursive;">发起人：【{{pidata.BranchName}}】{{pidata.CRUserName}} <span style="    position: absolute;right: 0px;" v-show="vtype == '0'" v-text="pidata.CRDate"></span> </p>

                                </el-col>

                            </el-row>


                        </div>
                        <div class="panel panel-default panbody" style="padding-bottom: 0PX;padding-top: 0PX;" :style="{'margin-bottom':pddata.ProcessType=='-1'?'80px':'0px' }">
                            <div class="success" v-show="formtatus =='1'">
                                <div class="success-tip">
                                    操作信息提示
                                    <i></i>
                                </div>
                                <div class="icon-tip">
                                    <div class="success-icon">
                                        <img src="/ViewV5/images/xt-right.png" />
                                    </div>
                                    <p></p>
                                </div>

                                <div class="tip-mesg">
                                    <el-button type="primary" icon="el-icon-view" style="border-radius:0px;" @click="ref()">查看该表单</el-button>
                                </div>
                            </div>
                            <el-row v-show="formtatus =='0'">
                                <el-form ref="form" label-position="top" :model="FormData">
                                    <component class="widget" v-for="(item, index) in FormData.wigetitems" :key="item.wigdetcode" :is="item.component" :index="index" :id="item.wigdetcode" :pzoption="item" style="margin-top:10px"></component>
                                </el-form>
                            </el-row>

                        </div>
                        <!--<div class="panel panel-default panwf" v-if="pddata.ProcessType=='1'" style="margin-bottom: 0px;">
                            <el-steps finish-status="success" align-center>
                                <el-step v-for="item in wfdata" :title="item.TaskName+'--'+item.TaskAssInfo" :status="stepstatus(item.state)">
                                    <span slot="description"> {{item.EndTime}}：{{item.userrealname}}<br /> {{item.TaskUserView}}</span>

                                </el-step>
                            </el-steps>
                        </div>-->
                        <div class="panel panel-default panwf" v-if="pddata.ProcessType=='1'" :style="{'margin-bottom':vtype=='0'?'0px':'80px' }">

                            <el-button type="text" @click="lcshow=!lcshow" style="margin-left: 5px;" v-text="lcshow?'隐藏流程':'显示流程'"><i class="el-icon-arrow-right el-icon--right"></i></el-button>
                            <el-collapse-transition>

                                <el-timeline v-show="lcshow">
                                    <el-timeline-item placement="top" v-for="(item, index) in wfdata" :timestamp="(index+1)+'：'+item.TaskName+'--'+item.TaskAssInfo" :type="stepstatus(item.state)">
                                        <el-card v-if="item.TIData.length>0||item.RBData.length>0" shadow="hover">
                                            <p v-for="ti in item.RBData" style="margin-top: 5px;color: #ff6a00;">【{{ti.IsHasManager}}】<span v-text="ti.TaskUser"></span> ：{{ti.UserView}} <span style="float:right" v-text="ti.Crdate"></span></p>
                                            <p v-for="ti in item.TIData" style="margin-top: 5px;color: #67c23a;"><span v-text="ti.zhuandanto"></span> ：{{ti.TaskUserView}} <span style="float:right" v-text="ti.EndTime"></span></p>

                                        </el-card>
                                    </el-timeline-item>
                                </el-timeline>
                            </el-collapse-transition>

                        </div>
                        <div class="panel panel-default panwf" id="FormFoot" style="padding-bottom: 20px;margin-bottom: 0px;" v-show="(formtatus =='0'&&pidata.isComplete != 'Y')||(pddata.ProcessType=='-1')">
                            <el-row>
                                <el-col :xs="24" :sm="12" v-show="qxdata.ISCANSP=='Y'&&tdpro.zhuandan">
                                    <div style="text-align:right;" class="hidden-print">

                                        <!--<span style="width:9%">转审</span>-->
                                        <el-select v-model="zsr" placeholder="请选择转审人" style=" width: 100%; margin-bottom: 10px;height:38PX" filterable clearable>
                                            <el-option v-for="item in zduser"
                                                       :key="item.UserName"
                                                       :label="item.BUSER"
                                                       :value="item.UserName">
                                            </el-option>
                                        </el-select>
                                    </div>

                                </el-col>
                                <el-col :xs="24" :sm="tdpro.zhuandan?12:24">
                                    <div style="text-align:right;" class="hidden-print">
                                        <el-button size="small" type="danger" v-on:click="CanCel" v-if="qxdata.ISCANCEL=='Y'&&pidata.isGD=='N'" style="border-radius:0px;"><i class="iconfont icon-chexiao1"></i>撤回</el-button>
                                        <el-button size="small" type="success" v-on:click="SaveForm" v-if="qxdata.ISCANCEL=='Y'&&pidata.isGD=='N'" style="border-radius:0px;">  <i class=" iconfont icon-gzbg"></i>  更新表单</el-button>
                                        <el-button size="small" type="success" v-on:click="ReForm" v-if="qxdata.ISCANSP=='Y'&&tdpro.zhuandan" style="border-radius:0px;"><i class="iconfont icon-chexiao1"></i>转审</el-button>
                                        <el-button size="small" type="success" v-on:click="ManageForm" v-if="qxdata.ISCANSP=='Y'" style="border-radius:0px;"><i class="iconfont icon-shenpi1"></i>{{tdpro.shname}}</el-button>
                                        <el-button size="small" type="danger" v-on:click="ReBack" v-if="qxdata.ISCANSP=='Y'&&(!tdpro.nocal||!tdpro.nocalre)" style="border-radius:0px;"><i class="iconfont icon-chexiao1"></i>退回</el-button>

                                    </div>

                                </el-col>

                            </el-row>
                        </div>

                    </div>

                </div>
            </el-main>
        </el-container>

        <el-dialog title="表单填写说明" :visible.sync="FormDecVisible">
            <div v-html="pddata.Alias">

            </div>
            <table class="table table-bordered table-hover" v-if="FormFile.length>0">
                <tr><th>附件</th></tr>
                <tr v-for="file in FormFile">
                    <td><a style="color:dodgerblue" v-bind:href="ComFunJS.getfile(file.ID)" v-text="file.Name"></a></td>
                </tr>
            </table>


            <div slot="footer" class="dialog-footer">
                <el-button type="primary" @click="FormDecVisible = false">关 闭</el-button>
            </div>
        </el-dialog>

        <el-dialog title="退回" :visible.sync="dialogCanVisible" id="candiv">
            <el-form>
                <el-form-item label="退回意见">
                    <el-input v-model="canyj" autocomplete="off"></el-input>
                </el-form-item>
                <el-form-item label="退回类型">
                    <el-radio-group v-model="canlx" style="width:100%">
                        <el-radio label="0" v-show="!tdpro.nocal">退回</el-radio>
                        <el-radio label="1" v-show="!tdpro.nocalre">退回到上一步</el-radio>
                    </el-radio-group>
                </el-form-item>
            </el-form>
            <div slot="footer" class="dialog-footer">
                <el-button @click="dialogCanVisible = false">取 消</el-button>
                <el-button type="primary" @click="ConReBack">确 定</el-button>
            </div>
        </el-dialog>

    </div>
    <script src="/ViewV5/JS/vue.js"></script>
    <script type="text/javascript" src="/ViewV5/JS/jquery-1.11.2.min.js"></script>
    <script src="/ViewV5/JS/lodash.min.js"></script>
    <script src="/ViewV5/JS/httpVueLoader.js"></script>
    <script src="/ViewV5/CSS/bootstrap3.3.5/js/bootstrap.js"></script>
    <!-- 引入组件库 -->
    <script src="/ViewV5/JS/element/element.js"></script>
    <script src="/ViewV5/JS/bijs.js?v=11"></script>
    <script src="/ViewV5/JS/Print.js?v=2"></script>
    <script src="FormManage.js?v=13"></script>

    <script type="text/javascript" charset="utf-8" src="/ToolS/ueditor/ueditor.config.js"></script>
    <script type="text/javascript" charset="utf-8" src="/ToolS/ueditor/ueditor.all.min.js"></script>
    <script type="text/javascript" charset="utf-8" src="https://cdn.jsdelivr.net/npm/@riophae/vue-treeselect@^0.4.0/dist/vue-treeselect.umd.min.js"></script>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@riophae/vue-treeselect@^0.4.0/dist/vue-treeselect.min.css">


    <script>
        function Preview() {
            $("#princontent").printThis({
                debug: false,
                importCSS: true,
                importStyle: true,
                printContainer: true,
                loadCSS: "/ViewV5/CSS/bootstrap3.3.5/css/bootstrap.css",
                pageTitle: "打印表单",
                removeInline: false,
                printDelay: 333,
                header: null,
                formValues: true
            });
        };
    </script>

</body>

</html>